

*note: use "youthparent.dta"
*82 to 97
reg relig97_ sorting82 relig82_ know97 interest97 hascollege white black catholic jewish sbaptist relignone male if pid3==1 & sorting97!=.
outreg, se bdec(2) starloc(1) replace
reg relig97_ sorting82 relig82_ know97 interest97 hascollege white black catholic jewish sbaptist relignone male if pid3==3 & sorting97!=.
outreg, se bdec(2) starloc(1) merge
reg sorting97 relig82_ sorting82 know97 interest97 hascollege white black catholic jewish sbaptist relignone male if pid3==1 & relig97!=. 
outreg, se bdec(2) starloc(1) merge
reg sorting97 relig82_ sorting82 know97 interest97 hascollege white black catholic jewish sbaptist relignone male if pid3==3 & relig97!=. 
outreg, se bdec(2) starloc(1) merge 

*interaction model
reg sorting97 pid3##c.relig82_ sorting82 know97 interest97 hascollege white black catholic jewish sbaptist relignone male if relig97!=.
quietly margins, at(relig82_=(0(.1)1) pid3=(1,3))
marginsplot

*descriptive 
sum relig97_ sorting82 relig82_ know97 hascollege white black catholic jewish sbaptist relignone male interest if sorting82!=. & relig82_!=.  & relig97_!=.  & know97!=. & interest!=., separator(0)

